﻿#pragma once
#include "Drillingrig_global.h"
#include <QVariant>
#include <QDebug>

class QJsonObject;
class AbstruactEventMediator;

class DRILLINGRIG_EXPORT EquipmentAction {
public:
	EquipmentAction() = default;
	virtual ~EquipmentAction() = default;
	virtual void update(QJsonObject const& msg) = 0;
	virtual void send(QJsonObject const& msg) = 0;
	virtual void send(QJsonObject const& msg, QStringView to) = 0;
	virtual void setMediator(AbstruactEventMediator* mediator) = 0;
	virtual QVariant request(QJsonObject const& obj, QStringView const requester) {
		Q_UNUSED(obj)
		Q_UNUSED(requester)
		qDebug() << __FUNCTION__ + QStringLiteral("结果未实现");
		return QVariant();
	};
	virtual QStringView identity() const = 0;
};